<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <title>Document</title>
    <link rel="stylesheet" href="./icon/iconfont.css">
    <style>
        .father{
            font-size:50px;
        }
        span::before{
            content: "";
            /* font-size: 50px; */
            color: red;
        }
        .mydiv{
            font-size:50px;
        }
        .mydiv::after{
            content: "哈哈";
            color: aqua;
        }
    </style>
</head>
<body>
    <div class="father">
        <!-- 给父盒子设置字体大小对icon图标无效果 -->
        <!-- icon图标实际上是加在了span::before的content上 -->
        <span class="iconfont icon-message"></span>
    </div>
    <div >
        <div class="mydiv">
            哈哈
        </div>
    </div>
    <div class="font"></div>
</body>
</html>